package com.dartfar.util;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.config.BeanPostProcessor;

public class DictionaryFactoryProcessor implements BeanPostProcessor  {
	
	public Object postProcessAfterInitialization(Object obj, String s) throws BeansException {  
		//DictionaryFactory为类名  
		if(obj instanceof DictionaryFactory){  
			//initDictionaryFactory为DictionaryFactory的方法   初始化数据字典
			((DictionaryFactory) obj).initDictionaryFactory();
		}  
		return obj;  
	}  
	
	public Object postProcessBeforeInitialization(Object obj, String s) throws BeansException {  
		return obj;  
	}  
}
